package com.rm.zeyou.pay.alipay.entity;

import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

import java.io.Serializable;

/**
 * 支付宝支付配置信息实体
 * 证书和密钥是二选一；配置密钥则不需要添加证书
 * @author zhangkechen
 * @since 2022/8/10 22:13
 */
@Data
@Component
@ConfigurationProperties(prefix = "alipay")
public class AlipayEntity implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 可选：AES密钥（接口内容加密方式），调用AES加解密相关接口时需要
     */
    private String encryptKey = "cAikHtKWeTYvCvw==";

    /**
     * 必填：协议类型：http | https 二选一
     */
    private String protocol = "https";

    /**
     * 必填：gatewayHost，默认：openapi.alipay.com
     */
    private String gatewayHost = "openapi.alipay.com";

    /**
     * 必填：签名类型，默认RSA2
     */
    private String signType = "RSA2";

    private String notifyIp;


}
